package com.dynamixsoftware.printershare.snmp;

import java.math.BigInteger;

public class SNMPCounter64
  extends SNMPInteger
{
  private static BigInteger maxValue = new BigInteger("18446744070000000000");
  
  public SNMPCounter64()
  {
    this(0L);
  }
  
  public SNMPCounter64(long paramLong)
  {
    this.tag = 70;
    this.value = new BigInteger(new Long(paramLong).toString());
    this.value = this.value.mod(maxValue);
  }
  
  protected SNMPCounter64(byte[] paramArrayOfByte)
    throws SNMPBadValueException
  {
    this.tag = 70;
    extractValueFromBEREncoding(paramArrayOfByte);
    this.value = this.value.mod(maxValue);
  }
  
  public void setValue(Object paramObject)
    throws SNMPBadValueException
  {
    if ((paramObject instanceof BigInteger))
    {
      this.value = ((BigInteger)paramObject);
      this.value = this.value.mod(maxValue);
      return;
    }
    if ((paramObject instanceof Integer))
    {
      this.value = new BigInteger(paramObject.toString());
      this.value = this.value.mod(maxValue);
      return;
    }
    if ((paramObject instanceof String))
    {
      this.value = new BigInteger((String)paramObject);
      this.value = this.value.mod(maxValue);
      return;
    }
    throw new SNMPBadValueException(" Counter64: bad object supplied to set value ");
  }
}


/* Location:           C:\Users\Admin\Desktop\Decompiler\JAD\jd-gui-0.3.6.windows\classes_dex2jar.jar
 * Qualified Name:     com.dynamixsoftware.printershare.snmp.SNMPCounter64
 * JD-Core Version:    0.7.0.1
 */